<?php use_stylesheets_for_form($form) ?>
<?php use_javascripts_for_form($form) ?>

<div class="cont-1">
    <form id="form" action="<?php echo url_for("give_money") ?>" method="post">
        <?php echo $form["amount"]->renderLabel() ?>
        <div class="in">
            <?php echo $form["amount"]->render(); ?>
            <?php if($form["amount"]->renderError() != NULL || $error != NULL):?>
            <div class="ui-state-error">
                <?php echo $form["amount"]->renderError() ?>
                <?php if($error != NULL): ?>
                    <?php echo $error ?>
                <?php endif; ?>
            </div>
            <?php endif;?>
        </div>
        <?php echo $form["to"]->renderLabel() ?>
        <div class="in">
            <?php echo $form["to"]->render(); ?>
            <?php if($form["to"]->renderError() != NULL):?>
            <div class="ui-state-error">
                <?php echo $form["to"]->renderError() ?>
            </div>
            <?php endif;?>
        </div>
        <?php echo $form["_csrf_token"]->render() ?>
        <input class="btn primary" type="submit" value="Donner" />
    </form>
</div>

